package com.snailhd.cloud.account.service.impl;

import com.snailhd.cloud.account.entity.UserDO;
import com.snailhd.cloud.account.mapper.AccountMapper;
import com.snailhd.cloud.account.spi.UserService;
import com.snailhd.common.entity.IResult;
import com.snailhd.cloud.redis.service.RedisService;
import lombok.extern.slf4j.Slf4j;
import org.apache.dubbo.config.annotation.Reference;
import org.apache.dubbo.config.annotation.Service;
import org.springframework.beans.factory.annotation.Autowired;

import javax.annotation.Resource;

/**
 *
 */

@Slf4j
@Service
public class UserServiceImpl implements UserService {

    @Resource
    RedisService redisService;

    @Resource
    AccountMapper accountMapper;


    @Override
    public IResult register() {
        return null;
    }

    @Override
    public UserDO queryByPhone(Long phone) {
        return accountMapper.queryByPhone(phone);
    }

    @Override
    public UserDO queryByEmail(String email) {
        return accountMapper.queryByEmail(email);
    }

    @Override
    public UserDO queryById(Long id) {
        return accountMapper.queryById(id);
    }



}
